Person: Test AG from 1010: Create
Legal Person As Partner| name | value |
|---|---|
| partnerPersonTradeName | Test AG |
| billingContactCaption | Billing GmbH - billing department |
| billingContactEmailAddress | billing@test-ag.example.org |
| debitorNumberSuffix | 02 |
| billable | true |
| vatId | VAT123456 |
| vatCountryCode | DE |
| vatBusiness | true |
| vatReverseCharge | false |
| defaultPrefix | tsy |
HTTP GET "/api/hs/office/persons?name=Test+AG" \
-H "Authorization: Bearer $HSADMINNG_JWT_BEARER" \
`# {` \
`# "sub" : "uuid<hsh-alex_superuser>"` \
`# }`
=> status: 200 OK
[ {
"uuid" : "9e12338f-c1ea-4237-9d64-f085a84850c6", // partnerPersonUuid
"personType" : "LEGAL_PERSON",
"tradeName" : "Test AG",
"salutation" : null,
"title" : null,
"givenName" : null,
"familyName" : null
} ]
In production, data this query could result in multiple outputs. In that case, you have to find out which is the right one.
HTTP POST "/api/hs/office/bankaccounts" \
-H "Authorization: Bearer $HSADMINNG_JWT_BEARER" \
`# {` \
`# "sub" : "uuid<hsh-alex_superuser>"` \
`# }` \
<<EOF
{
"holder" : "Billing GmbH - refund bank account",
"iban" : "DE02120300000000202051",
"bic" : "BYLADEM1001"
}
EOF
=> status: 201 CREATED a7fe2d92-2047-460b-b9bd-89018db51820
HTTP POST "/api/hs/office/contacts" \
-H "Authorization: Bearer $HSADMINNG_JWT_BEARER" \
`# {` \
`# "sub" : "uuid<hsh-alex_superuser>"` \
`# }` \
<<EOF
{
"caption" : "Billing GmbH, billing for Test AG",
"emailAddresses" : {
"main" : "test-ag@billing-GmbH.example.com"
}
}
EOF
=> status: 201 CREATED 4be81fd5-1aae-4a2f-b360-ed26dc464c0a
HTTP POST "/api/hs/office/debitors" \
-H "Authorization: Bearer $HSADMINNG_JWT_BEARER" \
`# {` \
`# "sub" : "uuid<hsh-alex_superuser>"` \
`# }` \
<<EOF
{
"debitorRel" : {
"anchor.uuid" : "9e12338f-c1ea-4237-9d64-f085a84850c6", // Person: Test AG
"holder.uuid" : "488e61a1-2c66-43a4-96cf-361fdcab9453", // Person: Billing GmbH
"contact.uuid" : "4be81fd5-1aae-4a2f-b360-ed26dc464c0a" // Contact: Billing GmbH - Test AG billing
},
"debitorNumberSuffix" : "02",
"billable" : true,
"vatId" : "VAT123456",
"vatCountryCode" : "DE",
"vatBusiness" : true,
"vatReverseCharge" : false,
"refundBankAccount.uuid" : "a7fe2d92-2047-460b-b9bd-89018db51820", // BankAccount: Billing GmbH - refund bank account
"defaultPrefix" : "tsy"
}
EOF
=> status: 201 CREATED 4ff1e229-058e-489d-bc3e-63f8c8ff744b
generated on 2026-08-10 04:34:21 for branch HEAD